package com.jd.finance.core.service;

import com.jd.finance.core.pojo.entity.Assign;
import com.baomidou.mybatisplus.extension.service.IService;
import com.jd.finance.result.BaseResult;
import org.apache.ibatis.annotations.Param;

import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 * 用户角色中间表 服务类
 * </p>
 *
 * @author LiQingBo
 * @since 2022-05-25
 */
public interface AssignService extends IService<Assign> {

    /**
     * 添加rbac中间表
     * @param uid 管理员id
     * @param uid1 用户id
     * @param roleId
     * @param request
     * @return
     */
    BaseResult addUserRole(@Param("uid") Integer uid, @Param("uid1") Integer uid1, @Param("roleId") Integer roleId, @Param("request") HttpServletRequest request);


    /**
     * 根据uid删除RBAC中间表
     * @param uid
     * @param leaveId
     * @param request
     * @return
     */
    BaseResult deleteUserRole(@Param("uid") Integer uid, @Param("leaveId") Integer leaveId, @Param("request") HttpServletRequest request);
}
